package top.chenfu1201.clientApi.mns.consumer;

import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

@Component
public class TopicReceiver {

    @RabbitListener(queues = {"xiaomi"})
    public void receiver1(String msg) {
        System.out.println("TopicReceiver-xiaomi:" + msg);
    }

    @RabbitListener(queues = {"huawei"})
    public void receiver2(String msg) {
        System.out.println("TopicReceiver-huawei:" + msg);
    }

    @RabbitListener(queues = {"phone"})
    public void receiver3(String msg) {
        System.out.println("TopicReceiver-phone:" + msg);
    }

}
